package be.kuleuven.mume.framework;

import java.util.Date;

import android.content.Context;
import android.text.format.DateFormat;
import be.kuleuven.mume.listProxys.DeviderProxy.Devidable;

public class Update implements Devidable{
	public static final String URL = Mobilenvi.getSingelton().BASEURL + "/api/updates";

	private String id;
	private String author;
	private String text;
	private String set;
	private String type;
	private String imageUrl;
	private String link;
	private Date date;
	
	public Update() {
		
	}
	
	public String getDevider(Context context) {
		java.text.DateFormat df = DateFormat.getDateFormat(context);
		return df.format(this.getDatum());
	}
	
	public Update(String text) {
		setText(text);
	}
	
	public String getGuid() {
		return id;
	}

	public void setGuid(String id) {
		this.id = id;
	}

	public void setAuthor(String author) {
		this.author = author;
	}

	public String getAuthor() {
		return author;
	}

	public void setText(String text) {
		this.text = text;
	}

	public String getText() {
		return text;
	}

	public void setSet(String set) {
		this.set = set;
	}

	public String getSet() {
		return set;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getType() {
		return type;
	}

	public void setImage(String imageUrl) {
		this.imageUrl = imageUrl;
	}

	public String getImage() {
		return imageUrl;
	}

	public void setLink(String link) {
		this.link = link;
	}

	public String getLink() {
		return link;
	}

	public void setDatum(Date date) {
		this.date = date;
	}

	public Date getDatum() {
		return date;
	}
}
